package com.tiancheng.trade.order.model.base;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.Version;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 实体基础信息
 *
 * @author echinacoop-yx01
 */
@Getter
@Setter
public class BaseEntity implements Serializable {
	/**
	 * 主键id
	 */
	@TableId(type = IdType.ASSIGN_ID)
	protected Long id;
	//@Version
	protected Integer version = 0;
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	protected LocalDateTime lastUpdDt;
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	protected LocalDateTime createdDt;
	protected String createdBy;
	protected String lastUpdBy;
}
